package org.example.socket网络编程.聊天室;

import java.io.*;
import java.net.ServerSocket;
import java.net.Socket;

public class Client {
    public static void main(String[] args) throws IOException {
        ServerSocket serverSocket = new ServerSocket(10001);
        // 接收消息
        Socket accept = serverSocket.accept();
        // 获取消息
        InputStream inputStream = accept.getInputStream();
        // 写出消息
        OutputStream outputStream = new BufferedOutputStream(new ByteArrayOutputStream());
        int len = 0;
        byte[] bytes = new byte[1024];
        while((len = inputStream.read(bytes)) != -1){

        }



    }
}
